package com.ktjiaoyu.server.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;

/**
 * <p>
 * 
 * </p>
 *
 * @author jjx
 * @since 2024-03-23
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("t_leavebill")
@ApiModel(value="Leavebill对象", description="")
public class Leavebill implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "请假标题")
    private String title;

    @ApiModelProperty(value = "请假内容")
    private String content;

    @ApiModelProperty(value = "请假天数")
    private Integer days;

    @ApiModelProperty(value = "请假开始时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
    private Date begintime;

    @ApiModelProperty(value = "请假结束时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
    private Date endtime;

    @ApiModelProperty(value = "请假状态(0-未提交 1-审批中  2-审批完成 3-已放弃)")
    private Integer state;

    @ApiModelProperty(value = "用户ID")
    private Integer userid;

    @TableField(exist = false)
    private Admin admin;


}
